<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<c:set var="ctx" value="${pageContext.request.contextPath }"></c:set>
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<title>个人信息</title>
<link rel="stylesheet" href="${ctx }/css/framework/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="${ctx }/css/index.css">
<link rel="stylesheet" href="${ctx }/css/user.css">

</head>

<body>
	<c:import url="nav.jsp"></c:import>


	<div class="container">
		<ol class="breadcrumb">
			<li><a href="${ctx}/toHome">首页</a></li>
			<li class="active">个人中心</li>
		</ol>

		<div class="row">
			<div class="col-md-3">
				<div class="panel panel-default">
					<div class="panel-heading">

						<c:if test="${empty(user.head_photo) }">
							<img src="${ctx }/images/defaulthead.png"
								class="img-responsive img-rounded" alt="Responsive image">
						</c:if>
						<c:if test="${!empty(user.head_photo) }">
							<img src="${user.head_photo}" class="img-responsive img-rounded"
								alt="Responsive image">
						</c:if>
						<h4>${user.user_name }</h4>
					</div>
				</div>

				<ul class="nav nav-sidebar">
					<li class="active"><a href="${ctx }/user/myzoom.html">个人信息
							<span class="sr-only">(current)</span>
					</a></li>
					<li><a href="${ctx }/user/myMatch.html">我的赛事</a></li>
					<li><a href="${ctx }/user_star.html">我的获奖</a></li>
					<li><a href="#">Application</a></li>
				</ul>
			</div>

			<div class="col-md-9 divline">
				<form class="form-horizontal mt-20">
					<div id="match_cover" class="form-group">
						<label class="title col-sm-2 control-label" for="cover">头像</label>
						<div class="col-sm-6">
							<div class="btn btn-primary">
								<input type="file" class="file-hide" id="cover"> 上传图片
							</div>
							<div class="imgPreview mt-10">
								<c:if test="${!empty(user.head_photo) }">
									<img src="${user.head_photo }">
								</c:if>
							</div>

						</div>
					</div>
					<div class="form-group">
						<label for="email" class="col-sm-2 control-label">账号 </label>
						<div class="col-sm-6">
							<input type="email" class="form-control" id="mail" name="mail"
								placeholder="请输入合法邮箱" value="${user.mail}" disabled="disabled">
						</div>
					</div>
					<div class="form-group">
						<label for="username" class="col-sm-2 control-label">真名 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="tureName"
								name="tureName" placeholder="请输入真名" value="${user.trueName}"
								disabled="disabled">
						</div>
					</div>
					<div class="form-group">
						<label for="school" class="col-sm-2 control-label">学校 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="school" name="school"
								placeholder="请输入您的学校" value="${user.university }"
								disabled="disabled">
						</div>
					</div>
					<div class="form-group">
						<label for="school" class="col-sm-2 control-label">学院 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="academy"
								name="academy" placeholder="请输入您的学校" value="${user.academy }"
								disabled="disabled">
						</div>
					</div>
					<div class="form-group">
						<label for="school" class="col-sm-2 control-label">专业 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="major" name="major"
								placeholder="请输入您的专业" value="${user.major}" disabled="disabled">
						</div>
					</div>
					<div class="form-group">
						<label for="school" class="col-sm-2 control-label">学号 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="studentId"
								name="studentId" placeholder="请输入您的学号"
								value="${user.studentId }">
						</div>
					</div>
					<div class="form-group">
						<label for="username" class="col-sm-2 control-label">用户名 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="username"
								name="user_name" placeholder="请输入用户名" value="${user.user_name}">
						</div>
					</div>

					<div class="form-group">
						<label for="telphone" class="col-sm-2 control-label">电话 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="phone" name="phone"
								placeholder="请输入电话" value="${user.phone }">
						</div>
					</div>
					<div class="form-group">
						<label for="address" class="col-sm-2 control-label">地址 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="address"
								name="address" placeholder="请输入您的所在地址"
								value="${user.detailaddress }">
						</div>
					</div>
					<div class="form-group">
						<label for="year" class="col-sm-2 control-label">毕业年份 </label>
						<div class="col-sm-6">
							<input type="text" class="form-control" id="year"
								name="graduate_year" placeholder="请输入您的毕业年份"
								value="${user.graduate_year }">
						</div>
					</div>
					<div class="form-group">
						<label for="profile" class="col-sm-2 control-label">个人简介 </label>
						<div class="col-sm-6">
							<textarea class="form-control" id='profile' name="profile"
								placeholder="请输入您的个人简介">
                                    	 ${user.profile }
                                    </textarea>
						</div>
					</div>
					<div class="form-group">
						<input type="hidden" class="form-control" name="use_id"
							value="${user.use_id}">
						<button class="btn btn-primary col-sm-1 col-sm-offset-2"
							type="button" id="info_btn">保存</button>
					</div>
				</form>
			</div>
		</div>
	</div>
	<c:import url="footer.jsp"></c:import>
	<script src="${ctx }/js/framework/jquery.min.js"></script>
	<script src="${ctx }/js/fileReader.js"></script>
	<script src="${ctx }/js/user_info.js"></script>
</body>

</html>